package com.blacktry.service;

import com.blacktry.entity.easypoidata.DeriveExcel;
import org.springframework.web.multipart.MultipartFile;

import javax.servlet.http.HttpServletResponse;
import java.io.IOException;
import java.io.UnsupportedEncodingException;
import java.net.MalformedURLException;
import java.util.List;

public interface EasyPoiService {
    String write(DeriveExcel deriveExcel) throws MalformedURLException;

    // 根据提供的List数据并导出
    void writeList(List<DeriveExcel> deriveExcelList, HttpServletResponse response) throws IOException;

    // 根据提供的ids数据并导出
    void writeListByIds(String[] ids, HttpServletResponse response) throws IOException;

    // 根据考试id导出Excel数据
    void writeExamByExamId(Integer examId, HttpServletResponse response) throws IOException;

    String readListByExcel(MultipartFile file);
}
